import { axios } from '@/utils/request'

export const getDictTypePage = (params) => {
  return axios({
    url: 'dict-type',
    method: 'get',
    params
  })
}

export const getDictTypeById = (id) => {
  return axios({
    url: 'dict-type/' + id,
    method: 'get'
  })
}

export const saveDictType = (data) => {
  return axios({
    url: 'dict-type',
    method: 'post',
    data
  })
}

export const updateDictTypeById = (id, data) => {
  return axios({
    url: 'dict-type/' + id,
    method: 'put',
    data
  })
}

export const removeDictTypeById = (id) => {
  return axios({
    url: 'dict-type/' + id,
    method: 'delete'
  })
}
